/*
 *    Copyright (c) 2018-2025, boss All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the boss developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: boss
 */

package com.hopes.bizz.risk.hid.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hopes.bizz.risk.common.constant.enums.RiskSysDictEnum;
import com.hopes.boss.admin.api.resolver.DictResolver;
import com.hopes.boss.admin.api.resolver.enums.AdminDictEnum;
import com.hopes.boss.common.entity.BaseLogicEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 三违考核
 *
 * @author pig
 * @date 2023-07-19 10:13:56
 */
@Data
@TableName("risk_hid_three_violation")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "三违考核")
public class RiskHidThreeViolationEntity extends BaseLogicEntity {

    private static final long serialVersionUID = 1L;


	/**
	* 标识
	*/
    @TableId(type = IdType.ASSIGN_ID)
    @Schema(description="标识")
    private Long id;

	/**
	* 源业务名称
	*/
    @Schema(description="源业务名称")
    private String bizName;

	/**
	* 源业务编码
	*/
    @Schema(description="源业务编码")
    private String bizCode;

	/**
	* 源业务标识
	*/
    @Schema(description="源业务标识")
    private Long bizId;

	/**
	* 三违行为类型
	*/
    @Schema(description="三违行为类型")
    private Integer threeType;

	/**
	* 三违描述
	*/
    @Schema(description="三违描述")
    private String threeDesc;

	/**
	* 违章人
	*/
    @Schema(description="违章人")
    private String violator;

	/**
	* 考核人部门
	*/
    @Schema(description="考核人部门")
    private Long assessmentDeptId;

	/**
	* 考核人
	*/
    @Schema(description="考核人")
    private Long assessmentUserId;

	/**
	* 违规发生时间
	*/
    @Schema(description="违规发生时间")
    private Date violationTime;

	/**
	* 违规照片
	*/
    @Schema(description="违规照片")
    private String violationImg;

	/**
	* 考核依据
	*/
    @Schema(description="考核依据")
    private String assessmentBasis;

	/**
	* 考核金额
	*/
    @Schema(description="考核金额")
    private BigDecimal assessmentAmount;

	/**
	* 违规发生地
	*/
    @Schema(description="违规发生地")
    private String violationLocation;

	/**
	* 机构ID
	*/
    @Schema(description="机构ID")
    private Long orgId;


	public String getThreeTypeStr(){
		return DictResolver.getItemLabelByValue(RiskSysDictEnum.three_type,this.threeType);
	}

	public String getAssessmentDeptIdStr(){
		return DictResolver.getItemLabelByValue(AdminDictEnum.sys_dept,this.assessmentDeptId);
	}

	public String getAssessmentUserIdStr(){
		return DictResolver.getItemLabelByValue(AdminDictEnum.sys_user,this.assessmentUserId);
	}

}
